package com.meichis.yndms.vm;

import androidx.lifecycle.MutableLiveData;

import com.meichis.yndms.model.BusinessBoard;
import com.meichis.yndms.repository.manager.BusinessBoardManager;

import java.util.List;

/**
 * @author xmy
 * @title
 * @remake
 * @create 2022-05-17 16:23
 */
public class ProductArrivalVM extends MyViewModel {

    //接口请求的所有数据
    private MutableLiveData<List<BusinessBoard>> allDatas;

    public MutableLiveData<List<BusinessBoard>> getAllDatas() {
        if (allDatas == null) {
            allDatas = new MutableLiveData<>();
        }
        return allDatas;
    }


    public void getMonthProductArrivalByBrand() {
        BusinessBoardManager.getInstance().getMonthProductArrivalByBrand(getShowDialog(),
                getUserInfo().getValue().getOrgId(), getUserInfo().getValue().getId(), getAllDatas());
    }
}
